# GENERATED BY: test/dependency_services/dependency_services_test.dart

$ cat pubspec.yaml
{"name":"myapp","dependencies":{"foo":"^1.0.0"},"environment":{"sdk":"^3.0.2"}}
$ cat pubspec.lock
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
  foo:
    dependency: "direct main"
    description:
      name: foo
      sha256: $SHA256
      url: "http://localhost:$PORT"
    source: hosted
    version: "1.1.1"
sdks:
  dart: ">=3.0.2 <4.0.0"
-------------------------------- END OF OUTPUT ---------------------------------

## Section report
$ echo '{"target":"foo","disallowed":[{"name":"foo","url":"http://localhost:$PORT","versions":[{"range":"1.1.1"},{"range":"1.1.2"}]}]}' | dependency_services report
{
  "dependencies": [
    {
      "name": "foo",
      "version": "1.1.1",
      "kind": "direct",
      "source": {
        "type": "hosted",
        "description": {
          "name": "foo",
          "url": "http://localhost:$PORT",
          "sha256": "effaacd54b31939dc8a71e3ccc6b14fa70f544a23a91d8b11eeba869d09cc789"
        }
      },
      "latest": "1.1.4",
      "constraint": "^1.0.0",
      "compatible": [
        {
          "name": "foo",
          "version": "1.1.4",
          "kind": "direct",
          "source": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "5c90f73bc6f153b0c6ab43579dea6dea0ab9aa9ff0244f780936e47303a7768c"
            }
          },
          "constraintBumped": "^1.0.0",
          "constraintWidened": "^1.0.0",
          "constraintBumpedIfNeeded": "^1.0.0",
          "previousVersion": "1.1.1",
          "previousConstraint": "^1.0.0",
          "previousSource": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "effaacd54b31939dc8a71e3ccc6b14fa70f544a23a91d8b11eeba869d09cc789"
            }
          }
        }
      ],
      "singleBreaking": [
        {
          "name": "foo",
          "version": "1.1.4",
          "kind": "direct",
          "source": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "5c90f73bc6f153b0c6ab43579dea6dea0ab9aa9ff0244f780936e47303a7768c"
            }
          },
          "constraintBumped": "^1.1.4",
          "constraintWidened": "^1.0.0",
          "constraintBumpedIfNeeded": "^1.0.0",
          "previousVersion": "1.1.1",
          "previousConstraint": "^1.0.0",
          "previousSource": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "effaacd54b31939dc8a71e3ccc6b14fa70f544a23a91d8b11eeba869d09cc789"
            }
          }
        }
      ],
      "multiBreaking": [
        {
          "name": "foo",
          "version": "1.1.4",
          "kind": "direct",
          "source": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "5c90f73bc6f153b0c6ab43579dea6dea0ab9aa9ff0244f780936e47303a7768c"
            }
          },
          "constraintBumped": "^1.1.4",
          "constraintWidened": "^1.0.0",
          "constraintBumpedIfNeeded": "^1.0.0",
          "previousVersion": "1.1.1",
          "previousConstraint": "^1.0.0",
          "previousSource": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "effaacd54b31939dc8a71e3ccc6b14fa70f544a23a91d8b11eeba869d09cc789"
            }
          }
        }
      ],
      "smallestUpdate": [
        {
          "name": "foo",
          "version": "1.1.3",
          "kind": "direct",
          "source": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "9ee54a074bcfbbb539b0458bd1c7e636bbccd85c4b202b9fce0a931ed63c472a"
            }
          },
          "constraintBumped": "^1.1.3",
          "constraintWidened": "^1.0.0",
          "constraintBumpedIfNeeded": "^1.0.0",
          "previousVersion": "1.1.1",
          "previousConstraint": "^1.0.0",
          "previousSource": {
            "type": "hosted",
            "description": {
              "name": "foo",
              "url": "http://localhost:$PORT",
              "sha256": "effaacd54b31939dc8a71e3ccc6b14fa70f544a23a91d8b11eeba869d09cc789"
            }
          }
        }
      ]
    }
  ]
}

-------------------------------- END OF OUTPUT ---------------------------------

$ cat pubspec.yaml
{"name":"myapp","dependencies":{"foo":"^1.0.0"},"environment":{"sdk":"^3.0.2"}}
$ cat pubspec.lock
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
  foo:
    dependency: "direct main"
    description:
      name: foo
      sha256: $SHA256
      url: "http://localhost:$PORT"
    source: hosted
    version: "1.1.1"
sdks:
  dart: ">=3.0.2 <4.0.0"
